﻿using Architecture.Domain.Dto;
using Architecture.Domain.Entity;
using Architecture.Domain.RBAC;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace Architecture.Service
{
    public interface IMenuService
    {
        Task<int> AddAsync(Menu model);
        Task<int> MenuDelete(int model);
        Task<int> UpdateAsync(Menu model);
        Task<Menu> GetByIdAsync(int id);
        Task<PageListDto<MenuDto>> GetAllAsync(int pageIndex, int pageSize, string? menuName);
        Task<List<Menu>> GetNameAsync();
        Task<List<Cascader>> MenuList(int id=0);
        /// <summary>
        /// 角色菜单关系权限表
        /// </summary>
        /// <param name="id"></param>
        /// <returns></returns>
        Task<object> PrivileFan(int id);

        //角色菜单表添加
        Task<int> GetRelatedAdd(int rId, List<int> mId);
    }
}
